package com.lovo;

import com.lovo.dto.UserDto;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;

import java.io.IOException;

@SpringBootApplication
public class DeadMain {
    public static void main(String[] args) {
        SpringApplication.run(DeadMain.class,args);
    }

    @RabbitListener(queues = "deadQueue")
    public void  deadMessage(UserDto userDto) throws IOException {
        System.out.println("死信："+userDto);

    }
}
